package net.xju3_4.entity;

import lombok.Getter;
import lombok.Setter;
import net.xju3_4.common.utils.DateUtils;
import java.math.BigDecimal;
import java.util.Date;


@Getter @Setter
public class PaymentEntity {
    private Integer id;             // 支付ID（主键）
    private Integer orderId;        // 订单ID
    private String paymentNo;       // 支付流水号
    private Integer paymentType;    // 支付方式（1-微信，2-支付宝）
    private BigDecimal amount;      // 支付金额
    private Date paymentTime;       // 支付时间
    private Date  refundTime;        // 退款时间
    private Integer status;         // 支付状态（0-未支付，1-已支付，2-已退款）

    private String totalAmount;
    private String totalOrder;
    private String totalRefundTime;
    private String year;
    private String month;


    private String paymentTimeStr;       // 支付时间
    private String   refundTimeStr;

    public String getPaymentTimeStr() {
        return DateUtils.parseDate2Str(paymentTime);
    }

    public String getRefundTimeStr() {
        return DateUtils.parseDate2Str(refundTime);
    }

    public PaymentEntity() {
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getOrderId() {
        return orderId;
    }

    public void setOrderId(Integer orderId) {
        this.orderId = orderId;
    }

    public String getPaymentNo() {
        return paymentNo;
    }

    public void setPaymentNo(String paymentNo) {
        this.paymentNo = paymentNo;
    }

    public Integer getPaymentType() {
        return paymentType;
    }

    public void setPaymentType(Integer paymentType) {
        this.paymentType = paymentType;
    }

    public BigDecimal getAmount() {
        return amount;
    }

    public void setAmount(BigDecimal amount) {
        this.amount = amount;
    }

    public Date getPaymentTime() {
        return paymentTime;
    }

    public void setPaymentTime(Date paymentTime) {
        this.paymentTime = paymentTime;
    }

    public Date getRefundTime() {
        return refundTime;
    }

    public void setRefundTime(Date refundTime) {
        this.refundTime = refundTime;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public String getTotalAmount() {
        return totalAmount;
    }

    public void setTotalAmount(String totalAmount) {
        this.totalAmount = totalAmount;
    }

    public String getTotalOrder() {
        return totalOrder;
    }

    public void setTotalOrder(String totalOrder) {
        this.totalOrder = totalOrder;
    }

    public String getTotalRefundTime() {
        return totalRefundTime;
    }

    public void setTotalRefundTime(String totalRefundTime) {
        this.totalRefundTime = totalRefundTime;
    }

    public void setPaymentTimeStr(String paymentTimeStr) {
        this.paymentTimeStr = paymentTimeStr;
    }

    public void setRefundTimeStr(String refundTimeStr) {
        this.refundTimeStr = refundTimeStr;
    }
}